package enums;

public enum PlayersLeft {
	few, some, many;
	
	public static PlayersLeft get(int playersLeft)
	{
		if(playersLeft < 5)
			return few;
		else if(playersLeft < 8)
			return some;
		else
			return many;
	}
	
	public static int getIndex(PlayersLeft playersLeft){

		int index = -1;
		for (int i = 0; i < PlayersLeft.values().length; i++) {
			if(playersLeft == PlayersLeft.values()[i]){
				index = i;
				return index;
			}
		}		
		return index;
	}
}
